package ai.fabu.dataplatform.service;

import ai.fabu.dataplatform.bean.front.GetFrontData;
import ai.fabu.dataplatform.bean.help.Position;
import ai.fabu.dataplatform.bean.task.GroupDataTask;
import ai.fabu.dataplatform.help.Result;
import ai.fabu.dataplatform.vo.groupdata.GroupDataGetVO;
import ai.fabu.dataplatform.vo.groupdata.GroupDataQueryVO;
import ai.fabu.dataplatform.vo.metadata.UpdateMetadataVO;
import ai.fabu.dataplatform.vo.task.GroupDataTaskImportVO;
import ai.fabu.dataplatform.vo.task.GroupDataTaskResetVO;
import org.springframework.stereotype.Service;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.List;
import java.util.Map;

public interface ApiForFrontService {
    String translateBeginTime(long beginTime);
    Result<List<String>> getMapNameOrVehicleNameAll(String name, int type);
    // task
    Result<String> readGroupREADME(String groupPath);
    Result importGroupAsTask(GroupDataTaskImportVO groupDataTaskImportVO);
    Result<List<GroupDataTask>> monitor(Long beginTime, Long endTime);
    Result<List<GroupDataTask>> getGroupDataTaskAll();
    Result resetGroupDataTask(GroupDataTaskResetVO groupDataTaskResetVO);


    Result<List<GetFrontData>> getDataByKeyList(GroupDataGetVO groupDataGetVO);
    Result<Map<String, Object>> queryGroup(GroupDataQueryVO groupDataQueryVO);
    Result updateGroupMetadata(UpdateMetadataVO updateMetadataVO);

    // user


    //
    Result<byte[]> getPointCloudImage(@NotBlank String groupName, @NotBlank String bagName, @NotBlank String topicName, @Min(1) int frameNo);

//    List<Position> utm2BaiduGps(List<Position> utmList);

//    Result generateLocalizationByName(@NotBlank String groupName);
//    Result generateBagRecordByName(@NotBlank String groupName);
//    Result generateGroupMapByName(@NotBlank String groupName);
//    Result generateBagGpsByName(@NotBlank String groupName);

    // temporary
    Result<Long> temporaryFunction1();
    Result<Long> temporaryFunction2();
    Result<Long> temporaryFunction3();
}
